package com.youlai.boot.system.model.form;

import java.io.Serial;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import java.time.LocalDateTime;
import java.math.BigDecimal;
import jakarta.validation.constraints.*;

/**
 * 商品管理表单对象
 *
 * @author zhangyurun
 * @since 2025-03-20 14:24
 */
@Getter
@Setter
@Schema(description = "商品管理表单对象")
public class ProductForm implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    private Long id;

    @Schema(description = "图片")
    private String pic;

    @Schema(description = "商品名称")
    @NotBlank(message = "商品名称不能为空")
    @Size(max=255, message="商品名称长度不能超过255个字符")
    private String productName;

    @Schema(description = "需要积分")
    @NotNull(message = "需要积分不能为空")
    private BigDecimal points;

    @Schema(description = "库存")
    @NotNull(message = "库存不能为空")
    private Integer stock;


}
